package quant.smart.crawl.utils;

import java.text.SimpleDateFormat;
import java.util.Date;
 
public class PrimaryUtil {
     
	public static String createDateId(String prefix) {
        Date date = new Date();
        SimpleDateFormat formatter = new SimpleDateFormat("yyyyMMdd");
        String id = prefix+formatter.format(date);
        return id;
    }
	public static String createMinuteId(String prefix) {
        Date date = new Date();
        SimpleDateFormat formatter = new SimpleDateFormat("yyyyMMddHHmm");
        String id = prefix+formatter.format(date);
        return id;
    }
    public static String createTimeId(String prefix) {
        Date date = new Date();
        SimpleDateFormat formatter = new SimpleDateFormat("yyyyMMddHHmmssSSS");
        String id = prefix+formatter.format(date);
        return id;
    }    
}
